<?php $this->load->view('config/header');?>
<h1>Picture Location <small>form entry</small></h1>
<ol class="breadcrumb">
  <li><a href="<?php echo site_url()?>home"><i class="icon-dashboard"></i> Dashboard</a></li>
  <li><a href="<?php echo site_url()?>location"><i class="icon-fullscreen"></i> Location</a></li>
  <li><a href="<?php echo site_url()?>locationpicture/index/<?php echo @$location[0]['id_location']?>"><i class="icon-fullscreen"></i> Picture Location</a></li>
  <li class="active"><i class="icon-file-alt"></i> Form <?php echo $mode; ?></li>
</ol>

<form class="form-horizontal" role="form" method="post" action="<?php echo site_url() ?>locationpicture/<?php echo $action; ?>" enctype="multipart/form-data">
	<input type="hidden" class="form-control" name="id_locationpic" value="<?php echo @$detail[0]['id_locationpic']?>">
	<input type="hidden" class="form-control" name="id_location" value="<?php echo @$location[0]['id_location']?>">
	<input type="hidden" class="form-control" name="date_locationpic" value="<?php echo @$detail[0]['date_locationpic']?>">

	<div class="form-group">
		<label for="file_locationpic" class="col-lg-2 control-label">File Picture</label>
		<div class="col-lg-6">
			<?php if(@$detail[0]['file_locationpic'] == "" || @$detail[0]['file_locationpic'] == "0"):?>
				<input type="file" class="form-control" name="file_locationpic"></input>
			<?php else:?>
				<input type="text" class="form-control" name="file_locationpic" value="<?php echo @$detail[0]['file_locationpic']?>" readonly="readonly"/>
			<?php endif;?>
		</div>
	</div>
	<div class="form-group">
		<label for="description_locationpic" class="col-lg-2 control-label">Description Picture</label>
		<div class="col-lg-6">
			<textarea name="description_locationpic" class="form-control" cols="50" rows="5" style="resize:none;"><?php echo @$detail[0]['description_locationpic']?></textarea>
		</div>
	</div>
	<div class="form-group">
		<div class="col-lg-offset-2 col-lg-10">
			<input type="submit" name="submit" value="Simpan" class="btn btn-primary"/>
			<a href="<?php echo site_url()?>locationpicture/index/<?php echo @$location[0]['id_location']?>" class="btn btn-primary">Batal</a>
		</div>
	</div>
</form>

<?php $this->load->view('config/footer');?>